package com.mofeng.myshop.mapper;

import com.mofeng.myshop.domain.po.Setting;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.mofeng.myshop.domain.po.UserBase;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 * 网站基础设置 Mapper 接口
 * </p>
 *
 * @author MoFeng
 * @since 2024-04-17
 */
public interface SettingMapper extends BaseMapper<Setting> {
    @Select("SELECT * FROM `tb_setting` WHERE `key_` = #{key}")
    Setting findByKey(@Param("key")String key);

    @Select("SELECT * FROM `tb_setting`")
    List<Setting> findAll();

}
